package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.ResOrderMapper;
import com.ruoyi.system.domain.ResOrder;
import com.ruoyi.system.service.IResOrderService;

/**
 * 餐馆订单Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-06-03
 */
@Service
public class ResOrderServiceImpl implements IResOrderService 
{
    @Autowired
    private ResOrderMapper resOrderMapper;

    /**
     * 查询餐馆订单
     * 
     * @param orderId 餐馆订单主键
     * @return 餐馆订单
     */
    @Override
    public ResOrder selectResOrderByOrderId(Long orderId)
    {
        return resOrderMapper.selectResOrderByOrderId(orderId);
    }

    /**
     * 查询餐馆订单列表
     * 
     * @param resOrder 餐馆订单
     * @return 餐馆订单
     */
    @Override
    public List<ResOrder> selectResOrderList(ResOrder resOrder)
    {
        return resOrderMapper.selectResOrderList(resOrder);
    }

    @Override
    public List<ResOrder> selectResOrderList1(ResOrder resOrder) {
        return resOrderMapper.selectResOrderList1(resOrder);
    }

    /**
     * 新增餐馆订单
     * 
     * @param resOrder 餐馆订单
     * @return 结果
     */
    @Override
    public int insertResOrder(ResOrder resOrder)
    {
        return resOrderMapper.insertResOrder(resOrder);
    }

    /**
     * 修改餐馆订单
     * 
     * @param resOrder 餐馆订单
     * @return 结果
     */
    @Override
    public int updateResOrder(ResOrder resOrder)
    {
        return resOrderMapper.updateResOrder(resOrder);
    }

    /**
     * 批量删除餐馆订单
     * 
     * @param orderIds 需要删除的餐馆订单主键
     * @return 结果
     */
    @Override
    public int deleteResOrderByOrderIds(Long[] orderIds)
    {
        return resOrderMapper.deleteResOrderByOrderIds(orderIds);
    }

    /**
     * 删除餐馆订单信息
     * 
     * @param orderId 餐馆订单主键
     * @return 结果
     */
    @Override
    public int deleteResOrderByOrderId(Long orderId)
    {
        return resOrderMapper.deleteResOrderByOrderId(orderId);
    }
}
